package com.block.channel.enums;

import cn.hutool.core.util.StrUtil;
import lombok.Getter;

@Getter
public enum ReportChannelEnum {

    SUOZHII("ZRPU76", "索知"),
    SUOZHII1("UOJ0F3", "索知1"),


    TUIA("4NY242", "推啊"),
    BIANXIANMAO("BHJAPW", "变现猫"),
    XIANGDIAN("ZSFIZ8", "享点"),
    JIZHUN("GIU2RK", "极准"),

    HUAWEI("huawei", "华为"),

    VIVO("vivo", "vivo"),
    XIAOMI("xiaomi", "小米"),

    BAIDU001("baidu001", "百度1"),
    BAIDU001LQB("baidu001lqb", "百度1lqb"),
    BAIDU001KEJIE("baidu001kejie", "百度1kejie"),

    BAIDU002("baidu002", "百度h5_11"),
    BAIDU003("baidu003", "百度h5_12"),
    BAIDU004("baidu004", "百度h5_13"),
    BAIDU005("baidu005", "百度h5_14"),
    BAIDU006("baidu006", "百度h5_15"),

    RONGYAO("rongyao", "荣耀"),

    ;

    String value;

    String name;

    ReportChannelEnum(String value, String name) {
        this.value = value;
        this.name = name;
    }

    public static boolean hasKey(String channelCode) {

        for (ReportChannelEnum channelEnum : values()) {
            if (StrUtil.equals(channelCode, channelEnum.getValue())){
                return true;
            }
        }
        return false;
    }
}

